import 'package:flutter/material.dart';
import 'package:codersun/pages/roots/tabs.dart';

class RegisterSetPwdPage extends StatefulWidget {
  final Map arguments;
  RegisterSetPwdPage({Key key, this.arguments}) : super(key: key);

  @override
  _RegisterSetPwdPageState createState() => _RegisterSetPwdPageState();
}

class _RegisterSetPwdPageState extends State<RegisterSetPwdPage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(title: Text('RegisterSetPwdPage')),
      body: Container(
          child: Column(
        children: <Widget>[
          SizedBox(height: 40.0),
          Padding(
            padding: EdgeInsets.fromLTRB(15.0, 0.0, 15.0, 0.0),
            child: TextField(
              decoration: InputDecoration(hintText: '请输入密码'),
            ),
          ),
          Padding(
            padding: EdgeInsets.fromLTRB(15.0, 0.0, 15.0, 0.0),
            child: TextField(
              decoration: InputDecoration(hintText: '再次请输入密码'),
            ),
          ),
          SizedBox(height: 20.0),
          Padding(
            padding: EdgeInsets.fromLTRB(15.0, 0.0, 15.0, 0.0),
            child: GestureDetector(
              child: Container(
                color: Colors.red,
                height: 44.0,
                child: Text('确定', style: TextStyle(color: Colors.white, fontSize: 16.0)),
                alignment: Alignment.center,
              ),
              onTap: () {
                Navigator.pushAndRemoveUntil(
                  context,
                  MaterialPageRoute(builder: (context) => Tabs(index: 2)),
                  (route) => route == null,
                );
              },
            ),
          )
        ],
      )),
    );
  }
}
